package PTA.javabianchengjichu2;

import java.util.Scanner;

public class ex37 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
  String str= sc.nextLine();
  if(str.equals("0")){
      return;
  }
String s[]=str.split("\\s+");

int arr[]=new int[s.length];
for(int i=0;i<s.length;i++){
    arr[i]=Integer.valueOf(s[i]);
}
double sum=0;
int count1=0;
int count2=0;
for(int i=0;i<arr.length;i++){
    if(arr[i]>0){
        count1++;
    }else if(arr[i]<0){
        count2++;
    }
    sum+=arr[i];
}
        System.out.println(count1);
        System.out.println(count2);
        System.out.println((int)sum);
        System.out.println(sum*1.0/(count1+count2));


    }
}
